package com.yanqu.xiuxian.crosssystem.manger.elementalbonds.param;

import com.yanqu.xiuxian.config.elementalbonds.ElementalBondsHardLevelConfig;

import java.util.ArrayList;
import java.util.List;

public class ElementalBondsAiMoveParam {

    private ElementalBondsMoveParam elementalBondsMoveParam;

    private boolean createBomb;
    private boolean combBoom;
    private boolean hasStepMpFull;
    private boolean boom;
    private boolean addMp;
    private boolean doubleEliminate;
    private boolean subMp;

    public int getWeight(ElementalBondsHardLevelConfig elementalBondsHardLevelConfig) {

        List<Boolean> list = new ArrayList<>();
        list.add(createBomb);
        list.add(combBoom);
        list.add(hasStepMpFull);
        list.add(boom);
        list.add(addMp);
        list.add(doubleEliminate);
        list.add(subMp);

        List<Integer> weightList = elementalBondsHardLevelConfig.getMoveWeightList();

        int weight = 0;
        for (int i = 0; i < list.size(); i++) {
            if (list.get(i)) {
                weight += weightList.get(i);
            }
        }
        return weight;
    }

    public ElementalBondsMoveParam getElementalBondsMoveParam() {
        return elementalBondsMoveParam;
    }

    public void setElementalBondsMoveParam(ElementalBondsMoveParam elementalBondsMoveParam) {
        this.elementalBondsMoveParam = elementalBondsMoveParam;
    }

    public void setCreateBomb(boolean createBomb) {
        this.createBomb = createBomb;
    }

    public void setCombBoom(boolean combBoom) {
        this.combBoom = combBoom;
    }

    public void setHasStepMpFull(boolean hasStepMpFull) {
        this.hasStepMpFull = hasStepMpFull;
    }

    public void setBoom(boolean boom) {
        this.boom = boom;
    }

    public void setAddMp(boolean addMp) {
        this.addMp = addMp;
    }

    public void setDoubleEliminate(boolean doubleEliminate) {
        this.doubleEliminate = doubleEliminate;
    }

    public void setSubMp(boolean subMp) {
        this.subMp = subMp;
    }

    public boolean isCreateBomb() {
        return createBomb;
    }

    public boolean isCombBoom() {
        return combBoom;
    }

    public boolean isHasStepMpFull() {
        return hasStepMpFull;
    }

    public boolean isBoom() {
        return boom;
    }

    public boolean isAddMp() {
        return addMp;
    }

    public boolean isDoubleEliminate() {
        return doubleEliminate;
    }

    public boolean isSubMp() {
        return subMp;
    }

}
